package com.kingmed.kmss.bpmn.modules.backup.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.kingmed.kmss.bpmn.modules.backup.model.BizApprovalStatus;
import com.kingmed.kmss.bpmn.modules.backup.model.BizApprovalTrail;
import com.kingmed.kmss.common.dto.bpmn.BizApprovalTrailDTO;
import com.kingmed.kmss.common.qc.bpmn.ApprovalTrailQC;

import java.util.List;

/**
 * <p>
 * 审批追踪表 服务类
 * </p>
 *
 * @author wzg
 * @since 2023-02-19
 */
public interface BizApprovalTrailService extends IService<BizApprovalTrail> {

	List<BizApprovalTrailDTO> queryApprovalTrail(ApprovalTrailQC qc);

	void saveApprovalTrail(BizApprovalTrail trail);

	String getProcInstIdByBiz(String bizType, String bizId);

	List<BizApprovalTrail> getMyCompleteProcesses(String bizType, String userId);

	Page<BizApprovalStatus> getMySubmitProcesses(String bizType, String userId, String currApprover, String auditStatus,
												 int pageNum, int pageSize, String startTime, String endTime,String requestByName);

	/**
	 * 根据流程实例id获取审批记录
	 */
	List<BizApprovalTrail> listByProcessInstanceId(String processInstanceId);
}
